package com.java.teachercode;

public class Consumer extends Thread {
    private BreadContainer bc;
    private int proCount;

    public Consumer(BreadContainer bc, String name, int proCount) {
        super(name);
        this.bc = bc;
        this.proCount = proCount;
    }

    @Override
    public void run() {
        bc.consume(proCount, getName());
    }


}
